{%include file="index.header.tpl.php"%}
{%include file="index.left.tpl.php"%}
 <style>
		@media only screen and (max-width: 760px),(min-device-width: 768px) and (max-device-width:1024px)  {
		table, thead, tbody, th, td, tr { 
			display: block; 
		}
		thead tr { 
			position: absolute;
			top: -9999px;
			left: -9999px;
		}
		td { 
			border: none;
			border-bottom: 1px solid #eee; 
			position: relative;
			padding-left:44% !important; 
			padding-top:10px ;
		}
	    #mytable tr{ margin-bottom:20px;}
		td:before { 
			position: absolute;
			top:10px;
			left:8px;
			width: 45%; 
			padding-right:10px;
			white-space: nowrap;
		}
		    td:nth-of-type(1):before { content: "教师姓名"; }
			td:nth-of-type(2):before { content: "班级名称"; }
			td:nth-of-type(3):before { content: "学科名称"; }
			td:nth-of-type(4):before { content: "周总课时"; }
			td:nth-of-type(5):before { content: "操作"; }
        }
		
	</style>
  <!--主要内容开始-->
  <div class="content-wrapper">
    <section class="content">
      <div class="row">
        <section class="col-lg-12 connectedSortable">
         <div class="box box-default box-solid">
             <form action="" method="POST">
                <div class="box-header with-border">
                    <span class="fa fa-table" style="float:left; font-size:18px; margin-top:2px; color:#3c8dbc;" ></span>
                    <p class="box-title">科任指派</p>
                </div>
                    <div class="box-body">
                       <div class="col-md-3 form-group">
						  <label for="inputPassword3" class="col-sm-3 control-label text-right" style="padding-right:0; padding-left:0; font-weight:500;">
							   老师：
						  </label>
						  <div class="input-group col-md-9 col-xs-12">
							  <input type="text" class="form-control"  name="staff_name">  
						  </div> 
				    </div>
                    <div class="col-md-3 form-group">
						  <label for="inputPassword3" class="col-sm-3 control-label text-right" style="padding-right:0; padding-left:0; font-weight:500; margin:0;">
							   班级：
						  </label>
						  <div class="input-group col-md-9 col-xs-12">
							  <select class="form-control" name="class_id">
							  {%foreach from=$class_lists key=key item=value%}
								<option></option>
                                <option value="{%$value.class_id%}">{%$value.class_name%}</option>
							  {%/foreach%}
                             
                              </select> 
						  </div> 
				    </div>
					<div class="col-md-3 form-group">
						  <label for="inputPassword3" class="col-sm-3 control-label text-right" style="padding-right:0; padding-left:0; font-weight:500; margin:0;">
							   学科：
						  </label>
						  <div class="input-group col-md-9 col-xs-12">
							  <select class="form-control" name="subject_id">
							  {%foreach from=$subject_lists key=key item=value%}
								<option></option>
                                <option value="{%$value.subject_id%}"> {%$value.subject_name%}</option>
							  {%/foreach%}
                                
                              </select> 
						  </div> 
				    </div>
					<div class="col-md-2 col-xs-12">
					   <button type="submit" class="btn btn-primary">查 询</button>
					</div>
                    <div style="clear:both; height:2px;"></div>
                    
                    
                        <table class="table table-bordered" id="mytable">
                           <thead>						 
                              <tr>
                                 <td>教师姓名</td>
                                 <td>班级名称</td>
                                 <td>学科名称</td>
                                 <td>周总课时</td>
								 <td>操作</td>
                              </tr>
							</thead>
							<tbody>
							 {%foreach from=$staff_lists key=key item=value%}	
                              <tr>
                                     <td>{%$value.staff_name%}</td>
									<!--班级-->
									 <td>
									{%foreach from=$value.class_name key=k item=v%}
										{%$v.class_name%}
									{%/foreach%}
									</td>
									<!--科目-->
									 <td>
									{%foreach from=$value.subject_name key=ke item=vl%}
										 {%$vl.subject_name%}
									{%/foreach%}
									</td>
                                     <td>30（完善后面功能后添加）</td>
                                     <td>
                                         <a href="index.php?a=subject.subjectassignupdate&staff_id={%$value.staff_id%}" class="btn btn-warning btn-xs"> 修  改 </a>
                                         <a href="" class="btn btn-danger btn-xs" onclick="if(confirm('警告！确认删除信息?')==false)return false;"> 删 除</a>
                                     </td>
                               </tr>
                               {%/foreach%}
                            </tbody>
                          </table>        					   
				    </div><!--box-body -->
                 </form>
				 {%$page%}
             </div><!--box box-default box-solid-->
        </section>   
           
        </div><!--row-->
    </section>
 </div>
  <!--主要内容结束-->
{%include file="index.footer.tpl.php"%}
